Visual Basic (Declaration) | |
---|---|
Overloads Public Shared Function CFrequencyTableAOR( _ ByVal seriesName As String, _ ByVal s As Series, _ ByVal boundaries() As Double _ ) As Series |
Visual Basic (Usage) | Copy Code |
---|---|
|
C# | |
---|---|
public static Series CFrequencyTableAOR( string seriesName, Series s, double[] boundaries ) |
Parameters
- seriesName
- The name of the series which will be displayed on the chart, i.e. its label.
- s
- A statistical series.
- boundaries
- A strictly increasing sequence of boundaries of the intervals over the real line in which the data sets point will be assigned.
Exception | Description |
---|---|
ArgumentException | Thrown if data set or boundaries intervals are null. |
Example
Within this example we work through an illustration in which the cumulative frequency table from above using the open right boundary convention is evaluated.
Consider the set of boundaries { 1, 2, 3, 4, 5 }
, which divide the real
line into six sub-intervals. Now if we use the open right boundary convention then
the real line will be divided into the sub-intervals:
(-infinity, 1), [1,2), [2,3), [3,4), [4,5), [5, infinity)
Note that, each point on the real line can be assigned to one of these sub-intervals
and therefore when assigning a data point to one of these intervals there will only
be one sub-interval in which it belongs.
Therefore, if we consider the data set { 0.5, 1.4, 1.3, 2.0, 2.3, 4.5, 5.5}
,
and if we assign this data set in accordance with the Open Right Boundary (ORB) convention
then we will have:
- Within the interval
(-infinity, 1)
, we assign the data element0.5
; and hence the frequency of this interval is1
. - Within the interval
[1, 2)
, we assign the data element1.4, 1.3
; and hence the frequency of this interval (wrt ORB convention) is2
. - Within the interval
[2, 3)
, we assign the data element2.0, 2.3
, and hence the frequency of this interval (wrt ORB convention) is2
. - Within the interval
[3, 4)
, we assign no data elements, and hence the frequency of this interval (wrt ORB convention) is0
. - Within the interval
[4, 5)
, we assign the data element4.5
, and hence the frequency of this interval (wrt ORB convention) is1
. - Within the interval
[5, infinity)
, we assign the data element5.5
, and hence the frequency of this interval (wrt ORB convention) is1
.
Now in follows that the associated values of the cumulative frequency table are given by:
- Cumulative frequency table above
-infinity
is:1 + 1 + 0 + 2 + 2 + 1 = 7
- Cumulative frequency table above
1
is:1 + 0 + 2 + 2 + 1 = 6
- Cumulative frequency table above
2
is:0 + 2 + 2 + 1 = 5
- Cumulative frequency table above
3
is:2 + 2 + 1 = 5
- Cumulative frequency table above
4
is:2 + 1 = 3
- Cumulative frequency table above
5
is:1
Hence, for this case the series returned by this methods to represent the cumulative
frequency table would be: {7, 6, 5, 5, 3, 1}
.